package com.etc.my.service;

import com.etc.my.dto.CollectionAndCarMessageDto;
import com.etc.my.dto.CollectionDto;
import com.etc.my.dto.CountDto;

import java.util.List;

public interface MyCollectionService {

    List<CollectionAndCarMessageDto> getCollectionByUserIdOfPage(Integer userId, Integer page , Integer size);

    CountDto getCollectionCountByUserId(Integer userId);

    /**
     * 取消收藏
     * @param collection_id 收藏id
     * @return true/false
     */
    boolean cancelCollectionById(Integer collection_id);

    /**
     * 车辆添加收藏
     * @param user_id 用户id
     * @param car_id 收藏的车辆id
     * @return
     */
    boolean addCollection(Integer user_id,String car_id);

    /**
     * 判断该用户是否已经收藏该车辆
     * @param user_id 用户id
     * @param car_id 车辆id
     * @return
     */
    boolean isCollection(Integer user_id,String car_id);

    /**
     * 根据车辆id和用户id取消收藏车辆
     * @param user_id 用户id
     * @param car_id 车辆id
     * @return true/false
     */
    boolean cancelCollectionByCarAndUserId(Integer user_id,String car_id);
}
